home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
X User Tools
/
X User Tools (O'Reilly and Associates)(1994).ISO
/
sun4c
/
archive
/
xgopher.z
/
xgopher
/
man
/
catn
/
xgopher.n
Wrap
Text File
|
1994-09-27
|
62KB
|
1,585 lines
XGOPHER(1) USER COMMANDS Release 5
NAME
xgopher - gopher client for the X window system
SYNTAX
xgopher [_r_o_o_t _s_e_r_v_e_r [_s_e_r_v_e_r _p_o_r_t]] [-_t_o_o_l_k_i_t_o_p_t_i_o_n ...]
DESCRIPTION
_x_g_o_p_h_e_r is an X window system client interface to the gopher
information server. Xgopher provides access to tremendous
amounts of information which may be accessed from a local
system or a remote information server. The source of the
information is generally transparent, with data supplied
from world-wide locations as easily as from a local on-
campus server.
The Gopher information system software is from the Univer-
sity of Minnesota.
OPTIONS
The installer of Xgopher normally configures the _r_o_o_t _s_e_r_v_e_r
and _s_e_r_v_e_r _p_o_r_t options. Loosely speaking, the root server
is the network name of the computer system that will provide
your initial gopher menu. The port is a number that speci-
fies system connection information. These options may also
be specified via the resources described later in this docu-
ment. For convenience, these options may be specified on
the command line.
The X toolkit options are standard options available to
every application written using the X toolkit (Xt). Please
refer to your Xt documentation for a list and description of
these options.
MAIN DISPLAY PANEL
The initial display will show the top level directory of
gopher information available. Selecting an item from this
list will fetch the contents of a file, subdirectory, or
other information. The directory display may be updated to
show the new subdirectory.
A gopher item is a menu entry in this directory list. There
are many types of gopher items handled by Xgopher, and each
is explained below.
An item is selected and highlighted by pointing at an entry
with the mouse and clicking the left button. To unselect
all items, click the mouse in either the directory title
area or bookmark title area.
You may select an entry in either the upper directory list
item or the lower bookmark list. The display button marked
X Version 11 1
XGOPHER(1) USER COMMANDS Release 5
Fetch selection is used to act on the selection. An
accelerator allows you to simply "click" a second time on a
highlighted item to activate the fetch.
By default, all interactions use only the left mouse button.
A directory is a collection of other files and directories.
The directory items are displayed in a list with an identi-
fying symbol to the left of each item. The symbol identi-
fies the type of the item. The symbols may be changed by
the installer or by each user. The default symbols are:
blank Text file
>> directory
<cso> a CSO name server (phone book)
<idx> a full text index search
<tel> a telnet session
<tn3> a tn3270 session
<img> an image file
<bin> a binary file
<snd> a sound file (spoken, sound effect, or music)
The file types are discussed below.
From all but the top level directory, the Previous Directory
button will return you to the previous directory that was
displayed just before this one. A keyboard accelerator
allows you to press the "u" key while the X pointer is any-
where on the main panel to achieve the same action.
BOOKMARKS
If you are viewing a directory that you may wish to return
to later, set a bookmark there with the Add directory as
bookmark button. This directory will be displayed with your
other bookmarks in the lower scrolling region below the
current directory list.
If you already have an item selected, the buttons label will
now read Add selection as bookmark and the item will be
added to the bookmark list.
Later, no matter where you have browsed through the gopher
directory space, you may return to any bookmark by selecting
X Version 11 2
XGOPHER(1) USER COMMANDS Release 5
it just as you would a regular directory item. You are
brought immediately to that marked directory, The directory
that you were in when you selected the bookmark becomes the
previous directory.
Other buttons and menu items let you remove individual book-
marks or all of the bookmarks.
The main gopher directory that you see when you first start
Xgopher is normally marked for you so you can easily and
quickly return to the top level.
Bookmarks are normally saved between your Xgopher sessions.
When your start Xgopher, the file $HOME/.gopherrc is read to
load your previous bookmarks, if any. When you exit Xgo-
pher, your current bookmark list is written back to this
file. Using the Option panel described below, you can
change the name of your bookmark file any number of times
during an Xgopher session, and use the Load bookmarks now
and Save bookmarks now commands to manipulate several files
of bookmarks.
The bookmark save file should be compatible with the Unix
curses client, bookmark file.
Other resources described below that may affect bookmark
processing are: bookmarkFile, loadBookmarks, appendBook-
marks, markRoot, and allowBookmarkSave.
INFORMATION ABOUT ITEMS
Each gopher item and directory may be maintained by a remote
computer system anywhere in the world. Sometimes it can be
difficult to determine where the information is coming from.
You can at least display the raw information which includes
the name of the computer (host) that serves each gopher
item.
If you are viewing a directory with no items currently
selected click the button labeled Info about directory, and
the information for this directory will be displayed.
If you already have an item selected, the buttons label will
now read Info about selection and information about the
selected item will be shown. The item that you select may
be from either the directory list or the bookmark list.
GOPHER ITEM TYPES
TEXT DISPLAYS
When the item selected from the directory list is a
text file, the contents of the file are fetched and
X Version 11 3
XGOPHER(1) USER COMMANDS Release 5
displayed as a pop-up text display window. Help infor-
mation is displayed in this way also.
The text display shows several command buttons and the
text itself in a vertically scrolling window. The but-
tons are:
Done to release this text file and window,
Page down to position the text down one page,
Page up to position the text up one page,
Print to send the contents of this file to the printer,
Save to save the contents of this file in a
user-specified file.
The Print or Save buttons may not always be available.
They may be disallowed by the installer or system-wide
resources file for Xgopher.
Text displays use the text widget from the MIT-supplied
Athena widget set. The text is given a read-only
attribute, but all of the position, search, and selec-
tion capabilities of the widget are available. For the
user who knows how to use these functions, there is
this additional power. For example, entering control-S
from the keyboard will bring up a text search panel
allowing you to scan for any string in the file. Other
control sequences allow more flexible text positioning
than is provided by the scroll bar and paging buttons.
All of these options are described in the Athena widget
set documentation of the text widget.
CSO NAME SERVER (Phone Book)
When the item selected is a CSO name server, a new win-
dow is displayed on the X display. The name of the
institution supporting the name server is displayed at
the top of the window. Below this are 4 areas. First
are the control buttons: Done closes the CSO name
server window; Help provides a text display with addi-
tional information; and Show Fields, discussed below.
The next area is a single line text entry field where
you type the name of the person you are looking up.
The name server will usually be able to find someone by
first name, last name, or both. Although, overly gen-
eral searches are prohibited. For example, trying to
look up "smith" is probably not a good idea in most of
the United States. After entering the name, type a
carriage return (enter) or click the mouse on the Do
query button to submit the request. Additional buttons
in the third area allow you to clear the query or
result text areas. The result is displayed in the
forth area, the bottom scrolling text region.
X Version 11 4
XGOPHER(1) USER COMMANDS Release 5
The Show Fields button displays a pop up menu. Select
an item from this menu to list the names and a brief
description of the fields in the data base being
searched. Note that these fields may be different for
every institution! Listing default fields will show
the things that are returned for a normal query (usu-
ally name, address, phone number, department, plus oth-
ers). Indexed fields are those that you can use to
search for (usually name and perhaps office phone).
Lookup fields are those that can be used to narrow the
search (for example, department). Finally, Public
fields are all the fields that can be viewed by every-
one.
A query may include more than just a name, for example,
legitimate queries are:
john smith
This will return every John Smith in the
selected data base. If there are more than a
handful, the name server will complain that
there are too many to give you. In this
case, you may want to try the next example.
smith department=biology
The department will help narrow the search to
only those people in the department of biol-
ogy.
j* smith department=biology
A "*" matches any characters and will help if
you are not sure of the exact spelling of a
name or only know initials.
john smith department=biology return all
The return option may specify a field you are
interested in or the value "all" to get all
public fields returned.
The CSO name server window may be left on the X display
as long as you like. Once displayed, it operates
independent of the gopher directory traversal. If you
want to switch to search another institution's phone
directory you can select it from the appropriate direc-
tory list without first closing a prior CSO name server
window. The same window is re-used for the currently
selected institution.
X Version 11 5
XGOPHER(1) USER COMMANDS Release 5
INDEX SEARCH
An index search is a very powerful way of obtaining a
list of documents which contain (or do not contain)
certain words. When you select an index search item, a
small pop-up panel asks you for a list of search words.
You can enter one or more words, plus the special
reserved boolean operators and, or, and not. For exam-
ple, if you want information on setting certain termi-
nal parameters for Unix, you may enter:
terminal and setting or tset
which will find all documents in the search space which
contain both the words "terminal" and "setting", or the
word "tset". The "or" is non-exclusive so the document
may contain all of the words. The input words may be
in upper- or lower-case, and will match words of either
case.
After entering the words, press carriage return (enter)
or click the mouse on the Do query button and the
search will be carried out.
The result of the index search looks very much like a
normal gopher directory of text files, but each file is
one that matches your specified criterion.
You will see a difference in the display of the text
file, however. Every word (or part of a word) that
matches the index words will be highlighted in the text
display. This allows you to quickly locate the parts
of a document that are interesting to you.
TELNET SESSION
Telnet sessions are normally text-based information
services, for example access to University library
holdings.
When you select an item which is identified as a telnet
session, A new xterm window (normal terminal emulator
window) will be created and it will be running a telnet
session. It may take a few seconds for the xterm win-
dow to show up. Some hosts that you connect to may
require you to enter a username (login name). If so,
then Xgopher will pop up an information window showing
you the name to use once the telnet session is started.
Many telnet sessions require you to enter a terminal
type as a part of the startup interaction. Usually,
you should choose vt100, as the xterm commands are very
similar to that of a DEC VT100 terminal.
X Version 11 6
XGOPHER(1) USER COMMANDS Release 5
Telnet sessions may be disallowed by the allowTelnet
resource described below. If telnet sessions are not
allowed, an error message will be displayed to that
effect.
TN3270 SESSION
tn3270 sessions are normally text-based information
services; similar in concept to telnet sessions, but
using a different terminal emulation protocol.
When you select an item which is identified as a tn3270
session, A new xterm window (normal terminal emulator
window) will be created and it will be running a tn3270
session. It may take a few seconds for the xterm win-
dow to show up. Some hosts that you connect to may
require you to enter a username (login name). If so,
then Xgopher will pop up an information window showing
you the name to use once the tn3270 session is started.
tn3270 sessions may be disallowed by the allowTn3270
resource described below. If tn3270 sessions are not
allowed, an error message will be displayed to that
effect.
For the X window system, X3270 is an alternative to
tn3270 that many people prefer. Whereas tn3270 exe-
cutes as an application within an xterm window and
doesn't understand X at all, X3270 is a true X applica-
tion.
tn3270 is available (vendor-supplied) on most Unix sys-
tems. X3270 is publicly available software, but not
supplied as a part of Xgopher. If your site provides
the X3270 program, you may use it instead of tn3270.
The IBM 3278 terminal character set and behavior is
closely emulated by X3270. Colors are used to distin-
guish normal, bold, and input fields. Every key on the
keyboard may be mapped to a 3278 function using one of
the supplied keyboard maps or the X application
defaults file.
The following commands are usually built into Xgopher
or the system resources file when the program is
installed, but you may modify your own application
resources to use a command such as the following for
tn3270:
xterm -e tn3270 or aixterm -e tn3270 (for
IBM AIX systems)
X Version 11 7
XGOPHER(1) USER COMMANDS Release 5
If you choose X3270 instead, the command is:
x3270
IMAGES
When an image file is selected for processing, Xgopher
retrieves the file, then runs another program to
display the image on an X display. This second program
is often _x_l_o_a_d_i_m_a_g_e. The installer of Xgopher, or any
user, may change this to be any other program that is
available. _x_l_o_a_d_i_m_a_g_e is a particularly nice program
because it will display other file types besides GIF
using heuristics to determine the type of the file.
The imageCommand resource specifies the command that
will be used to display the image. Interesting choices
are:
xloadimage (normal behavior, with mes-
sages output)
xloadimage -quiet(the Xgopher default - no
messages)
xv (another nice gif viewer
available)
Neither _x_l_o_a_d_i_m_a_g_e nor _x_v are a part of the Xgopher
distribution. Many sites that run X already have one
of these programs installed.
A large image may take many seconds to appear as con-
siderable processing may be required before the
display. Several images may be displayed at once. The
way to remove an image depends on the command used to
display the image. For _x_l_o_a_d_i_m_a_g_e, typing the letter
"q" within the picture display will remove the image.
The allowImage resource may be used to disallow pro-
cessing of image files.
BINARY FILES
Binary file types are not precisely defined in the
gopher community, but many Unix files that are
compressed (.Z) or tar archives (.tar) are assigned the
same binary item type in gopher (type 9). When you
select one of these files, Xgopher prompts you for a
file name on your local system. The dialog box that
pops up for this file name will suggest the same name
as the remote file; you may change this name if it is
not satisfactory. The files are then processed (or
fetched) by simply copying the data to your specified
X Version 11 8
XGOPHER(1) USER COMMANDS Release 5
file. Processing a binary type of gopher item with the
Fetch selection button is identical to using the Copy
command on the same item.
The allowCopy resource determines whether copying is
allowed. If not, a message is displayed.
SOUNDS
If Xgopher is executing on a workstation that supports
sounds, then you can play files containing spoken
words, sound effects, or music through Xgopher.
Selecting a sound file will cause that file to be
"played" through your workstation's audio device. Only
a single sound file can be active at a time; you will
be warned if you try to play a sound before a previous
one is through. Use the application resources hasSound
and soundCommand described below. Note that your X
display may be remote from the computer that is execut-
ing the Xgopher application. Your sounds may be coming
across loud and clear on a computer system some dis-
tance away from your display.
COPYING FILES DIRECTLY
The Copy item in the Other Commands menu can be used to copy
a gopher item directly to a file without first processing or
displaying the gopher data. If the item type is a text
file, an ascii mode copy will be done, preserving end-of-
line conventions for your system. Other data files and unk-
nown item types are copied in binary mode until an end of
file is encountered. It makes no sense to copy directories,
CSO name servers, index directories, or telnet sessions, so
the copy command will reject requests to copy these.
When you chose the Copy command, Xgopher prompts you for a
file name on your local system. The dialog box that pops up
for this file name will suggest the same name as the remote
file; you may change this name if it is not satisfactory.
The copy command is one way to access gopher item types that
are not normally processed by Xgopher.
If the allowCopy resource is false, then the copy command is
not shown in the menu.
DIRECT ENTRY OF A GOPHER ITEM
This function is not for the beginning or casual user of
Gopher. Sometimes a reference is available to a specific
gopher item available, perhaps without specifying all the
menus to traverse. If you know all the access information
X Version 11 9
XGOPHER(1) USER COMMANDS Release 5
for a piece of data anywhere in gopher space, you may use
the Enter Gopher Item command in the Other Commands menu to
directly access this data. When you select this command a
panel is displayed for you to enter the type, path, host,
port, and optionally name of the item. A help display is
available to explain these items a bit more.
A neat trick: Any gopher data can be fetched as a text file
by entering its host/path/port and setting the type to 0
(ascii text file). Even a directory can be fetched as text
in this way. Similarly, any gopher data may be retrieved as
binary by setting the type to 9 (binary file type). This
works even for types unknown to Xgopher.
OPTIONS PANEL
Some Xgopher options may be changed during a session. These
are available on the Options Panel pop up display which is
selected from the Other Commands menu. The bookmark file,
and system commands for printing, image display, and telnet
sessions may be changed using this panel.
A help display is available with this panel to further
describe the options.
If the optionsButton resource is false, then the Options
Panel command is not shown in the menu.
RESOURCES
The application class is Xgopher. Most of the user-
interface is configured in the app-defaults file; if this
file is missing a warning message will be printed to stan-
dard error and the program will terminate. All of the
important defaults are established in the system app-
defaults file, normally installed as /usr/lib/X11/app-
defaults/Xgopher.
The defaults mentioned below may have been changed by the
installer for a specific system. They may all be overridden
in by individual preferences. The application specific
resources are grouped below by category.
Startup
rootServer (class RootServer)
Specifies the initial gopher information server
host name as an internet address.
rootPort (class RootPort)
The port number of the top level gopher server
to connect to. The supplied default is 70.
X Version 11 10
XGOPHER(1) USER COMMANDS Release 5
rootPath (class RootPath)
The initial selector string or path name to
retireve the top level menu. The supplied
default is the null string.
helpFile (class HelpFile)
This is the absolute or relative path name of
the file to be displayed when the _h_e_l_p command
button is depressed. The supplied default is
/usr/lib/X11/xgopher/xgopher.help
mainTitle (class MainTitle)
The main title displayed above the listing of
the top level directory. The supplied default
is "UIUC Gopher Information Service".
bookmarkFile (class bookmarkFile)
The name of the file containing Xgopher book-
marks. This is also the file that bookmarks
will be written to when you exit Xgopher. This
file name may be changed during a session using
the options panel.
Unlike other file names, if the path name does
not have a leading slash or tilde then the path
name is assumed relative to your home direc-
tory. The supplied default is "~/.gopherrc".
loadBookmarks (class loadBookmarks)
Whether or not to load bookmarks automatically
when Xgopher starts. The supplied default is
True.
External Commands
printCommand (class PrintCommand)
This is the print command used to spool a print
request. Useful examples of print commands are
_l_p_r or _e_n_s_c_r_i_p_t. The gopher internal file name
containing the text is appended to the end of
the command supplied. As an option, if the 2
characters %s appear in the print command
string anywhere, they are replaced by the file
name. The %s may even appear more than once.
If %s appears, then the file name is not
appended to the end. The supplied default is:
"# print" without the quotes. It is a comment.
telnetCommand (class TelnetCommand)
The command Xgopher will use to start a telnet
session. The host and port number are added to
the end of this command. The resulting command
X Version 11 11
XGOPHER(1) USER COMMANDS Release 5
is executed (via the _s_y_s_t_e_m(_3) function) to
provide a telnet session. In general, the tel-
net command should be executed by an xterm as
with the default (_x_t_e_r_m -_e _t_e_l_n_e_t). In some
environments (such as OpenWindows), it may be
useful to specify the full path name of both
the xterm and telnet commands. For example,
/_u_s_r/_b_i_n/_X_1_1/_x_t_e_r_m -_e /_u_s_r/_u_c_b/_t_e_l_n_e_t. This
command should be disabled for secure environ-
ments such as public access terminals, as it is
easy to start a shell from a telnet session.
The supplied default is "xterm -e telnet"
(without the quotes).
tn3270Command (class Tn3270Command)
The command Xgopher will use to start a tn3270
session. The host and port number are added to
the end of this command. The resulting command
is executed (via the _s_y_s_t_e_m(_3) function) to
provide a tn3270 session. In general, the
tn3270 command should be executed by an xterm
as with the default (_x_t_e_r_m -_e _t_n_3_2_7_0). In some
environments (such as OpenWindows), it may be
useful to specify the full path name of both
the xterm and tn3270 commands. For example,
/_u_s_r/_b_i_n/_X_1_1/_x_t_e_r_m -_e /_u_s_r/_u_c_b/_t_n_3_2_7_0. This
command should be disabled for secure environ-
ments such as public access terminals, as it is
easy to start a shell from a tn3270 session.
Examples of useful tn3270 commands are:
Xgopher.tn3270Command: xterm -e
tn3270
Xgopher.tn3270Command: aixterm -e
tn3270 (for IBM AIX systems)
Xgopher.tn3270Command: x3270
The supplied default is "xterm -e tn3270"
(without the quotes).
imageCommand (class ImageCommand)
The command to use to display an image file to
the X display screen. The name of the local
temporary file containing the image is appended
to the end of this command before it is exe-
cuted. This command is never executed if the
allowImage resource is False. The supplied
default is "xloadimage -quiet" (without the
quotes).
soundCommand (class SoundCommand)
The command to use to get a sound file from the
X Version 11 12
XGOPHER(1) USER COMMANDS Release 5
standard input stream (_s_t_d_i_n) to the audio dev-
ice. On many workstations this command may be
called "_p_l_a_y". Another command which may be
useful is "_c_a_t > /_d_e_v/_a_u_d_i_o". The supplied
command is started by Xgopher as a separate
process with sound data fed into its standard
input. This command is never executed if the
hasSound resource is False. The supplied
default is "play" (without the quotes).
Behaviour
showItems (class ShowItems)
Controls which gopher items will be displayed
in the menus. The valid values of this
resource are: "All", "Known", "Accessible", or
"Available". The value All will display every
gopher item returned by the gopher server, even
types not understood by Xgopher. Known will
display every gopher item that Xgopher can pro-
cess (including extend types). Accessible will
show only those items that the user can fetch
or process in this session subject to security
resources such as "allowTelnet" which may bar
access to certain items. Available items are
those that can be processed by pushing the
"fetch" button; the intersection of Accessible
and Known items. The supplied default is All.
appendBookmarks (class AppendBookmarks)
When this resource is true, loading a new book-
mark file will append the new bookmarks to your
current list. When false, the new bookmarks
will replace the current list. The supplied
default is True.
warpCursor (class WarpCursor)
If true, the mouse pointer is automatically
positioned by Xgopher whenever a save, index,
or CSO name server panel is popped up. The new
position is a location within a new window so
you can immediately start typing without having
to move the mouse. The supplied default is
False. doubleClick (class DoubleClick) Nor-
mally a gopher item or directory is selected by
"clicking" on it. Then the _F_e_t_c_h button is
pressed to process the request. If this
resource is true, the fetch action may be
invoked by simply re-selecting the same item
already selected. This is a double-click on
that item, although with no time limit between
clicks. It may be disabled for example, if a
X Version 11 13
XGOPHER(1) USER COMMANDS Release 5
touch sensitive screen replaces the mouse, to
ensure more reliable operation. The supplied
default is True.
statusWindow (class StatusWindow)
Use a popup window to show Xgopher status and
activity. This contains usally one to three
lines of text plus a cancel button. If this
resource is false, then status is only shown in
the status bar area just below the topmost row
of buttons. The supplied default is True.
nameText (class NameText)
When this resource is true, a text window's
icon will be given the name of the text item
(as is in the window title bar). If false,
each text window will have a common name, which
is "Gopher Text" by default (this common icon
label may also be changed using the resource
Xgopher*textShell.iconName). The supplied
default is True.
markRoot (class MarkRoot)
When true, a bookmark is automatically set at
the top lever (root) directory. If you do not
want to have this bookmark set, change the
value of this resource to False. The supplied
default is True.
concurrentText (class ConcurrentText)
Normally each request for a text, help, or item
information causes a new popup window to be
displayed which remains displayed until it is
dismissed with its "done" button. The number
of windows displayed may be limited by setting
this resource to a (usually small) number
greater than zero. When number of windows
displayed reaches this limit, the oldest will
be reused for the next text to be shown. The
window will be re-used in place without being
popped down, yielding some time savings for
slower or networked X servers. Also see com-
monText and allowHold. The supplied default is
0.
commonText (class CommonText)
There are three types of data displayed using a
similar text window: gopher text files, xgopher
help information, and item information from the
"info" button. Each of these is normally con-
sidered a separate type of text popup for
counting against the limit imposed by
X Version 11 14
XGOPHER(1) USER COMMANDS Release 5
concurrentText. If commonText is True, then
all three types of data are considered the same
and together count against the limit. Also see
concurrentText and allowHold. The supplied
default is False.
resetOptions (class ResetOptions)
Options changed on the options panel popup will
be reset to their original default values when
a restart command occurs if this resource is
true. The supplied default is True.
logFile (class LogFile)
If a file name is provided, all directory
changes, remote host connections, and errors
are logged to this file. If nothing else, it
provides a trail of where you have been and
allows some simple diagnostics to determine
what remote machines are not accessible. If no
file name is provided, no logging occurs. The
supplied default is no log file.
hasSound (class HasSound)
This flag indicated whether the computer exe-
cuting Xgopher has the ability to play general
sounds, such as spoken words, sound effects,
and music. For example, an X terminal will not
normally have this ability, but some worksta-
tions such as the Sun SparcStation can play
sounds. Note that if your display is remote
from the computer with sound capability someone
else may be deriving the benefit of your sound.
Therefore this resource should indicate that
sounds will be played nearby. The supplied
default is False.
Extended Types
For considerably more detail on extended types, their
use, and examples, please see the document Extended-
types that is part of the Xgopher source distribution.
extendedTypes (class ExtendedTypes)
A list of individual characters which represent
additional gopher types to be processed by Xgo-
pher. All internal types can be overridden by
an extended type except directories and index
directories (types 1 and 7). The types are
processed and introduced to Xgopher in the
order they are listed in this string. The sup-
plied default is none. The following are sub-
resources, each qualified by a name composed of
X Version 11 15
XGOPHER(1) USER COMMANDS Release 5
the new extended type character. If X is an
extended type, then each of the following
resources is fully qualified as
Xgopher.typeX._____.
sameAs (class SameAs)
The letter identifier of an internal type or
previously defined external type. This pro-
vides an alias saying that this new type is the
same as some other type. However, the descrip-
tion, prefix, servers, and dataType may be dif-
ferent for this type. The supplied default is
none.
description (class Description)
A short string used in the info popup and
status messages describing the type of this
item. Typical names are "image file", "index
search", etc. The supplied default is "type X
item", where X is the extended type letter.
prefix (class Prefix)
A menu display prefix string for items of this
type. The supplied default is "< X >", where X
is the extended type letter.
servers (class Servers)
The gopher servers that can supply this item
type. See "textServers" for more information.
The supplied default is none.
dataType (class DataType)
The type of data the gopher server will provide
for this type. The values are None, Ascii, or
Binary. None says that no additional data is
provided, the execCommand is usually sufficient
(an example is the telnet item type). Ascii or
Binary determine the translations of the data
received. Text type files should be specified
as Ascii, image, sound, and similar data should
be Binary. The supplied default is None.
execCommand (class ExecCommand)
The command to execute for processing this
gopher item. Substitutions are made in this
string in a manner similar to a C printf call.
A percent sign signals the start of a replace-
ment. The values used are taken verbatim from
the gopher item. The following replacements
are performed:
%h hostname string
X Version 11 16
XGOPHER(1) USER COMMANDS Release 5
%p port number
%P if port number is 0 or 23, then
blank, otherwise the port number. A
hack for telnet sessions.
%s selector (path) string
%n name (menu name) string
%f filename of the temp file string
%% percent sign
If any other character follows the percent, then no
special substitution is performed. The supplied
default is None.
wait (class Wait)
If true, then the entire Xgopher application
will await the completion of this process
before continuing. If the execCommand forks
itself and terminates, Xgopher may be easily
deceived into believing that the process has
completed before the task is really done. The
supplied default is False.
Security
allowPrint (class AllowPrint)
If this boolean resource is true, text
displayed in pop up windows may be spooled to a
printer by depressing a _P_r_i_n_t button. If
False, the button will not be displayed. The
supplied default is True.
allowSave (class AllowSave)
If this boolean resource is true, text
displayed in pop up windows may be saved to a
user-specified file by depressing a _S_a_v_e but-
ton. If False, the button will not be
displayed. The supplied default is True.
allowHold (class allowHold)
If concurrentText is greater than zero,
requesting that the number of concurrent text
windows is limited, a "hold" button will be
added to each text pop-up window. If the hold
button is pressed then this text window will be
held on the screen until explicitly dismissed
with the "done" button. This mechanism
X Version 11 17
XGOPHER(1) USER COMMANDS Release 5
effectively overrides the concurrentText
resource, and thus may be disabled by setting
allowHold to False. Also see concurrentText
and commonText. The supplied default is True.
allowTelnet (class AllowTelnet)
If this boolean resource is true, telnet ses-
sions are allowed. If False, they are inhi-
bited with an error message displayed to that
effect. This resource should be False in
secure environments such as public access ter-
minals, as it is easy to start a shell from a
telnet session. The supplied default is True.
allowTn3270 (class AllowTn3270)
If this boolean resource is true, tn3270 ses-
sions are allowed. If False, they are inhi-
bited with an error message displayed to that
effect. This resource should be False in
secure environments such as public access ter-
minals, as it is easy to start a shell from a
tn3270 session. The supplied default is True.
allowCopy (class AllowCopy)
If this boolean resource is true, the Copy but-
ton is displayed and files may be directly
copied to a user-specified file. Also, binary
files may be fetched. If False, the button
will not be displayed, and binary file access
will be disallowed. The supplied default is
True.
allowBookmarkSave (class AllowBookmarkSave)
The current bookmark list will be written to
the current bookmark file when you exit or res-
tart Xgopher if this resource is true. The
bookmark file name may be changed during a ses-
sion using the options panel. The supplied
default is True.
allowImage (class AllowImage)
If this boolean resource is true, image display
is allowed. If false, it is inhibited with an
error message displayed to that effect. The
supplied default is True.
optionsButton (class OptionsButton)
The Options panel button in the Other Commands
menu will not be displayed if this resource is
false. Then, no resources may be changed dur-
ing a session. The supplied default is True.
X Version 11 18
XGOPHER(1) USER COMMANDS Release 5
singleItemButton (class SingleItemButton)
The Enter gopher item button in the Other Com-
mands menu will not be displayed if this
resource is false. Then, you cannot directly
enter a gopher item descriptor. The supplied
default is True.
textServers (class Servers)"
A list of trusted servers hosts or domains from
which text files will be accepted. An empty
list means that text files can be retrieved
from any server. The list can contain host
names, domain names, IP address numbers, or
partial addresses that specify a domain. The
list must contain exact names of the trusted
hosts, no host aliases are used. This resource
may be useful on a public-access system to
prevent abuse or limit the extent of gopher
space. If textServers is used, then it is pru-
dent to also set allowFtp to False. The sup-
plied default is none.
imageServers (class Servers)"
Same as the textServers resource, but for image
files. The supplied default is none.
soundServers (class Servers)"
Same as the textServers resource, but for sound
files. The supplied default is none.
allowFtp (class AllowFtp)"
Allow or disallow gopher accesses that specify
an ftp request. This resource may be used to
limit the extent of gopher space for a public-
access Xgopher terminal.
publicMode (class publicMode)
This is more of a meta resource used to set
many security-related resources at once. When
set to True, publicMode sets the following
values:
Xgopher.allowSave: False
Xgopher.allowPrint: False
Xgopher.allowTelnet: False
Xgopher.allowTn3270: False
Xgopher.allowBookmarkSave: False
Xgopher.allowCopy: False
Xgopher.appendBookmarks: True
Xgopher.loadBookmarks: True
Xgopher.markRoot: True
Xgopher.resetOptions: True
X Version 11 19
XGOPHER(1) USER COMMANDS Release 5
Xgopher.optionsButton: False
Xgopher.singleItemButton: False
Xgopher.showItems: Available
You should also consider setting the following which
are NOT automatically set by publicMode:
Xgopher.allowImage: False
Xgopher.hasSound: False
(or use imageServers/soundServers to control access),
Xgopher.warpCursor: True
Xgopher.doubleClick: False
Xgopher.concurrentText: 1
Xgopher.allowHold: False
Xgopher.allowFtp: False
Xgopher.bookmarkFile: <filename>
the next two should go as a pair:
Xgopher.restartButton: False
Xgopher.swapRestartAndQuit: True
Also, be sure that any remaining commands (imageCom-
mand, soundCommand, etc.) have no shell-escapes or
other ways to do damage.
restartButton (class RestartButton)
If false, the Restart command button in the Other
Options menu will not be displayed. This is most
useful in conjunction with the swapRestartAndQuit
resource. The supplied default is True.
swapRestartAndQuit (class SwapRestartAndQuit)
If true, the functions of the quit and restart but-
tons are swapped. Remember to also change the but-
ton labels. This may be used in a public-access
Xgopher terminal to easily retreat to a known state,
but not-too-easily terminate Xgopher entirely. The
supplied default is False.
Popup Positioning
For considerably more detail on positioning popup win-
dows, including examples, please see the document Pop-
ups that is part of the Xgopher source distribution.
The following are sub-resources, each qualified by a
name of a popup, for example, Xgopher.Popup._____.
positionFrom (class PositionFrom)
X Version 11 20
XGOPHER(1) USER COMMANDS Release 5
The supplied default is from_none.
xPosition (class Position)
The supplied default is 0.
yPosition (class Position)
The supplied default is 0.
horizontalJustification (class Justification)
The supplied default is Left.
verticalJustification (class Justification)
The supplied default is Top.
xPercent (class Percent)
The supplied default is True.
yPercent (class Percent)
The supplied default is True.
Prefixes
prefixFile (class PrefixFile)
This prefix is shown in the directory listing
to the left of text files. The supplied
default is blank for text files.
prefixDir (class PrefixDir)
This prefix is shown in the directory listing
to the left of directory entries. The supplied
default is 273 (an octal escape sequence),
which is a single character in the Latin-1
character set which looks like >>.
prefixCSO (class PrefixCSO)
This prefix is shown in the directory listing
to the left of entries which are CSO name
servers (phone books). The supplied default is
<cso>.
prefixTelnet (class PrefixTelnet)
This prefix is shown in the directory listing
to the left of entries which are telnet ses-
sions. The supplied default is <tel>.
prefixTn3270 (class PrefixTn3270)
This prefix is shown in the directory listing
to the left of entries which are tn3270 ses-
sions. The supplied default is <tn3>.
prefixIndex (class PrefixIndex)
This prefix is shown in the directory listing
X Version 11 21
XGOPHER(1) USER COMMANDS Release 5
to the left of entries which are full text
index searches. The supplied default is <idx>.
prefixImage (class PrefixImage)
This prefix is shown in the directory listing
to the left of entries which are image files.
The supplied default is <img>.
prefixBinary (class PrefixBinary)
This prefix is shown in the directory listing
to the left of entries which are binary files.
The supplied default is <bin>.
prefixSound (class PrefixSound)
This prefix is shown in the directory listing
to the left of entries which are sound files.
The supplied default is <snd>.
prefixUnknown (class PrefixUnknown)
This prefix is shown in the directory listing
to the left of entries which are unknown file
types. This prefix is displayed if showItems
is All or Accessible. The supplied default is <
? >.
Performance and Configuration
directoryTime (class DirectoryTime)
Directory entries for all active directories
(current directory, directories with bookmarks,
and all of their ancestors) are saved for this
many seconds. After this time, their contents
are released and re-requested from the
appropriate place when needed. This caching of
directory contents makes moving up the direc-
tory tree and jumping to bookmarks quite fast.
The very small potential risk is that the con-
tents of a directory in a gopher server may be
changed while the directory is stored. The
caching, freeing, and reloading of directories
is transparent to the user. The supplied
default is 600. This is 10 minutes.
itemStart (class ItemStart)
Not normally changed by the user, this deter-
mines the amount of memory dynamically allo-
cated when xgopher starts execution to hold
gopher items (directory contents). The sup-
plied default is 500.
itemIncrement (class ItemIncrement)
Not normally changed by the user, this
X Version 11 22
XGOPHER(1) USER COMMANDS Release 5
determines the amount of memory dynamically
allocated each time xgopher needs additional
memory to hold gopher items (directory con-
tents). The supplied default is 50.
dirStart (class DirStart)
Not normally changed by the user, this deter-
mines the amount of memory dynamically allo-
cated when xgopher starts execution to hold
gopher directories. The supplied default is
50.
dirIncrement (class DirIncrement)
Not normally changed by the user, this deter-
mines the amount of memory dynamically allo-
cated each time xgopher needs additional memory
to hold gopher directories. The supplied
default is 10.
tempDirectory (class TempDirectory)
The directory for xgopher to create files that
it will need for display or other purposes, but
will not exist beyond this xgopher session.
The supplied default is /tmp.
Widget specific resources:
The X Toolkit and Athena Widgets documentation covers the
widget specific resources. The most significant widget
specific resources are mentioned here.
font (class Font)
All text, label, and command button widgets have a
font that can be selected.
label (class Label)
All command button widgets and many labels text
strings may be changed, for example to another
language.
FILES
/usr/local/lib/X11/app-defaults/Xgopher
/usr/local/lib/X11/xgopher.help
SEE ALSO
There is a collection of documents included with the Xgopher
distribution that may be useful to the installer or users of
Xgopher. These include guides for porting Xgopher, defining
new gopher types for Xgopher, and notes that will aid in
customization an Xgopher environment.
X Version 11 23
XGOPHER(1) USER COMMANDS Release 5
Installers should see the internal documentation for changes
to the configuration file before compiling and installing
Xgopher.
BUGS
The gopher+ protocol is not yet supported.
COPYRIGHT
Copyright 1992, 1993 by the Board of Trustees of the Univer-
sity of Illinois
This program with copyright notice intact may be freely dis-
tributed without permission.
AUTHOR
Allan Tuchman, Computing and Communications Services Office,
University of Illinois at Urbana-Champaign, Urbana, Illi-
nois, USA. email to: a-tuchman@uiuc.edu.
X Version 11 24